package com.imagination.applet.domain.fsImage.model;

import com.imagination.applet.domain.adapter.OSSConfiguration;
import com.imagination.applet.domain.common.entity.AbstractEntity;
import jakarta.persistence.*;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.SuperBuilder;

@SuperBuilder
@Entity
@Table(name = "t_face_swap_images")
@Getter
@Setter
@ToString
@AllArgsConstructor
public class FaceSwapImage extends AbstractEntity {

    public static String PREFIX_PATH = "/fsimages/";

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @Column(name = "user_id")
    private Long userId;

    @Column(name = "serial_no ")
    private String serialNo;

    @Column(name = "photo_id")
    private Long photoId;

    @Column(name = "ai_image_id")
    private Long aiImageId;

    @Column(name = "image_path")
    private String imagePath;

    public String getPath() {
        return OSSConfiguration.path + FaceSwapImage.PREFIX_PATH + imagePath;
    }

    public String getLink() {
        return "";
    }
}
